AbiPy v0.9.1 @IMEC

M. Giantomassi and the AbiPy group

IMEC seminar
June 10 2022 - Leuven, BE


Use the Space key to navigate through all slides and SHIFT + Space key to go back one slide.

What is AbiPy?

Python package for:

  • Generating ABINIT input files automatically
  • Post-processing results extracted from netcdf or text files
  • Interfacing ABINIT with external tools such as vesta, wannier90, lobster, etc.
  • Running ABINIT-specific workflows on laptops as well as on HPC clusters

Dependencies:

NB: AbiPy can be interfaced with other packages (e.g ASE, phonopy) via converters.

AbiPy design principles

  • Extend the pymatgen code-base with ABINIT-specific objects
  • Layered structure designed for different use-cases:

    • Post-processing tools and command-line interfaces
    • API to automate calculations and data analysis
    • High-throughput infrastructure (abiflows, fireworks, mongodb)
  • Closely connected to the ABINIT executable:

    • CPU-intensive algorithms performed by ABINIT (Fortran + MPI + OpenMP)
    • Glue code implemented in python
  • ABINIT and AbiPy communicate through binary netcdf files

How to install AbiPy

Using conda and the conda forge channel (recommended):

    conda install abipy --channel conda-forge

Since conda is not limited to python packages, one can install ABINIT in the same env with:

    conda install abinit -c conda-forge      


Using pip and python wheels:

    pip install abipy --user


For further info see this installation howto

AbiPy documentation

In [9]:
%embed https://abinit.github.io/abipy/index.html
Out[9]:

Notebooks with examples and lessons

In [11]:
%embed https://nbviewer.jupyter.org/github/abinit/abitutorials/blob/master/abitutorials/index.ipynb
Out[11]:

Command line interface

  • abiopen.py ➝ Open output files inside ipython or print/visualize file
  • abistruct.py ➝ Operate on crystalline structures read from file
  • abicomp.py ➝ Compare multiple files (i.e. convergence studies)
  • abiview.py ➝ Quick visualization of output files
  • abinp.py ➝ Generate input files for typical calculations
  • abigui.py ➝ Start local web server with AbiPy GUI

Documentation

  • abistruct.py --help for manpage
  • abistruct.py COMMAND --help for help about COMMAND

HTML documentation available at http://abinit.github.io/abipy/scripts/index.html

abiopen.py

In [12]:
!abiopen.py si_scf_GSR.nc --print  # or -p
================================= File Info =================================
Name: si_scf_GSR.nc
Directory: /Users/gmatteo/git_repos/abipy_imec_2022
Size: 14.83 kb
Access Time: Mon Jun  6 23:58:53 2022
Modification Time: Mon Jun  6 23:53:36 2022
Change Time: Mon Jun  6 23:53:36 2022

================================= Structure =================================
Full Formula (Si2)
Reduced Formula: Si
abc   :   3.866975   3.866975   3.866975
angles:  60.000000  60.000000  60.000000
Sites (2)
  #  SP       a     b     c  cartesian_forces
---  ----  ----  ----  ----  -----------------------------------------------------------
  0  Si    0     0     0     [-5.89948306e-27 -1.93366149e-27  2.91016904e-27] eV ang^-1
  1  Si    0.25  0.25  0.25  [ 5.89948306e-27  1.93366149e-27 -2.91016904e-27] eV ang^-1

Abinit Spacegroup: spgid: 227, num_spatial_symmetries: 48, has_timerev: True, symmorphic: True

Stress tensor (Cartesian coordinates in GPa):
[[5.21161758e+00 7.86452261e-11 0.00000000e+00]
 [7.86452261e-11 5.21161758e+00 0.00000000e+00]
 [0.00000000e+00 0.00000000e+00 5.21161758e+00]]

Pressure: -5.212 (GPa)
Energy: -241.23647031 (eV)

============================== Electronic Bands ==============================
Number of electrons: 8.0, Fermi level: 5.598 (eV)
nsppol: 1, nkpt: 29, mband: 8, nspinor: 1, nspden: 1
smearing scheme: none (occopt 1), tsmear_eV: 0.272, tsmear Kelvin: 3157.7
Direct gap:
    Energy: 2.532 (eV)
    Initial state: spin: 0, kpt: [+0.000, +0.000, +0.000], weight: 0.002, band: 3, eig: 5.598, occ: 2.000
    Final state:   spin: 0, kpt: [+0.000, +0.000, +0.000], weight: 0.002, band: 4, eig: 8.130, occ: 0.000
Fundamental gap:
    Energy: 0.562 (eV)
    Initial state: spin: 0, kpt: [+0.000, +0.000, +0.000], weight: 0.002, band: 3, eig: 5.598, occ: 2.000
    Final state:   spin: 0, kpt: [+0.375, +0.375, +0.000], weight: 0.012, band: 4, eig: 6.161, occ: 0.000
Bandwidth: 11.856 (eV)
Valence maximum located at kpt index 0:
    spin: 0, kpt: [+0.000, +0.000, +0.000], weight: 0.002, band: 3, eig: 5.598, occ: 2.000
Conduction minimum located at kpt index 17:
    spin: 0, kpt: [+0.375, +0.375, +0.000], weight: 0.012, band: 4, eig: 6.161, occ: 0.000

TIP: Use `--verbose` to print k-point coordinates with more digits

To produce a predefined set of matplotlib figures, use:

abiopen.py mgb2_kpath_FATBANDS.nc --expose --seaborn  # or -e -sns

abiopen_expose

Replace --expose with --notebook to generate notebook with predefined python code

ABINIT abo/log files are supported as well:

abiopen.py gs_dfpt.abo --expose --seaborn

To start a web GUI for FILE, use the --panel option:

abiopen.py out_DDB --panel  # or -pn if you prefer the short option.

Convert structure from netcdf format to CIF (abivars, xsf, poscar, qe, siesta, wannier90, json)

In [13]:
!abistruct.py convert si_scf_GSR.nc -f cif
# generated using pymatgen
data_Si
_symmetry_space_group_name_H-M   'P 1'
_cell_length_a   3.86697464
_cell_length_b   3.86697464
_cell_length_c   3.86697464
_cell_angle_alpha   60.00000000
_cell_angle_beta   60.00000000
_cell_angle_gamma   60.00000000
_symmetry_Int_Tables_number   1
_chemical_formula_structural   Si
_chemical_formula_sum   Si2
_cell_volume   40.88829233
_cell_formula_units_Z   2
loop_
 _symmetry_equiv_pos_site_id
 _symmetry_equiv_pos_as_xyz
  1  'x, y, z'
loop_
 _atom_site_type_symbol
 _atom_site_label
 _atom_site_symmetry_multiplicity
 _atom_site_fract_x
 _atom_site_fract_y
 _atom_site_fract_z
 _atom_site_occupancy
  Si  Si0  1  0.00000000  0.00000000  0.00000000  1
  Si  Si1  1  0.25000000  0.25000000  0.25000000  1

Are you still using cut3d to export the structure in a format that other applications can understand?

abistruct.py visualize run_si02.abi

Supports also ovito, xcrysden, vtk, mayavi, matplotlib (Use --application option)

Connect to the materials project database to find similar structures.

In [15]:
!abistruct.py mp_match si_scf_GSR.nc
# Found 2 structures in Materials Project database (use `verbose` to get further info)

 
########################### abivars input for this ###########################
# Full Formula (Si2)
# Reduced Formula: Si
# abc   :   3.866975   3.866975   3.866975
# angles:  60.000000  60.000000  60.000000
# 
# Spglib space group info (magnetic symmetries not taken into account).
# Spacegroup: Fd-3m (227), Hall: F 4d 2 3 -1d, Abinit spg_number: 227
# Crystal_system: cubic, Lattice_type: cubic, Point_group: m-3m
# 
#   Idx  Symbol    Reduced_Coords              Wyckoff      EqIdx
# -----  --------  --------------------------  ---------  -------
#     0  Si        +0.00000 +0.00000 +0.00000  (2a)             0
#     1  Si        +0.25000 +0.25000 +0.25000  (2a)             0

 natom 2
 ntypat 1
 typat 1 1
 znucl 14
 xred
    0.0000000000    0.0000000000    0.0000000000
    0.2500000000    0.2500000000    0.2500000000
 acell    1.0    1.0    1.0
 rprim
    6.3285005521    0.0000000000    3.6537614973
    2.1095001840    5.9665675402    3.6537614973
    0.0000000000    0.0000000000    7.3075229946



 
########################## abivars input for mp-149 ##########################
# Full Formula (Si2)
# Reduced Formula: Si
# abc   :   3.866975   3.866975   3.866975
# angles:  60.000000  60.000000  60.000000
# 
# Spglib space group info (magnetic symmetries not taken into account).
# Spacegroup: Fd-3m (227), Hall: F 4d 2 3 -1d, Abinit spg_number: None
# Crystal_system: cubic, Lattice_type: cubic, Point_group: m-3m
# 
#   Idx  Symbol    Reduced_Coords              Wyckoff      EqIdx
# -----  --------  --------------------------  ---------  -------
#     0  Si        +0.25000 +0.25000 +0.25000  (2b)             0
#     1  Si        +0.00000 +0.00000 +0.00000  (2b)             0

 natom 2
 ntypat 1
 typat 1 1
 znucl 14
 xred
    0.2500000000    0.2500000000    0.2500000000
    0.0000000000    0.0000000000    0.0000000000
 acell    1.0    1.0    1.0
 rprim
    0.0000000000    5.1671990850    5.1671990850
    5.1671990850    0.0000000000    5.1671990850
    5.1671990850    5.1671990850    0.0000000000



Need to call anaddb to compute and visualize ph-bands and DOS from DDB?

abiview.py ddb ZnSe_hex_qpt_DDB --seaborn

Add --phononwebsite to visualize data on the phononwebsite by H. Miranda

To compare multiple structures:

In [16]:
!abicomp.py structure *.cif si_nscf_GSR.nc *_DDB
Spglib options: symprec= 0.001 angle_tolerance= 5.0
Lattice parameters:
                  formula  natom  alpha  beta  gamma         a         b  \
AlAs.cif          Al1 As1      2   60.0  60.0   60.0  3.970101  3.970101   
si.cif                Si2      2   60.0  60.0   60.0  3.866975  3.866975   
si_nscf_GSR.nc        Si2      2   60.0  60.0   60.0  3.866975  3.866975   
ZnSe_hex_qpt_DDB  Zn2 Se2      4   90.0  90.0  120.0  4.050187  4.050187   
alas_DDB          Al1 As1      2   60.0  60.0   60.0  3.970101  3.970101   
elastic_DDB       Al2 As2      4   90.0  90.0  120.0  3.989448  3.989448   

                         c     volume abispg_num spglib_symb  spglib_num  \
AlAs.cif          3.970101  44.247584       None       F-43m         216   
si.cif            3.866975  40.888292       None       Fd-3m         227   
si_nscf_GSR.nc    3.866975  40.888292        227       Fd-3m         227   
ZnSe_hex_qpt_DDB  6.652328  94.504936          0      P6_3mc         186   
alas_DDB          3.970101  44.247584          0       F-43m         216   
elastic_DDB       6.497130  89.552529          0      P6_3mc         186   

                 spglib_lattice_type  
AlAs.cif                       cubic  
si.cif                         cubic  
si_nscf_GSR.nc                 cubic  
ZnSe_hex_qpt_DDB           hexagonal  
alas_DDB                       cubic  
elastic_DDB                hexagonal  
 

Using ElectronBandsPlotter to visualize multiple band structures:

abicomp.py ebands *_GSR.nc

AbiPy API

AbiPy post-processing tools

  • Main entry point:

    from abipy import abilab
    abifile = abilab.abiopen("filename.nc")
    

    where filename.nc is a netcdf file (support also text files e.g. run.abo, run.log, out_DDB)

  • abifile is the AbiFile subclass associated to the given file extension:

    1. GSR.nc ➝ GsrFile
    2. HIST.nc ➝ HistFile
    3. More than 45 file extensions supported (see abiopen.py --help)

AbiPy plots with matplotlib

In [17]:
gsr = abiopen("si_nscf_GSR.nc")
gsr.ebands.plot(with_gaps=True);

AbiPy plots with plotly

In [18]:
gsr.ebands.plotly(with_gaps=True);  # obj.plot becomes obj.plotly

To upload the plotly figure to the chart studio server, use:


gsr.ebands.plotly(with_gaps=True, chart_studio=True);

Users can finally customize the AbiPy plot without changing the python code 🎉

Interactive 3d plots with plotly:

In [19]:
gsr.ebands.kpoints.plotly(title="k-path in 3d with plotly");

and, ça va sans dire, phonons from DDB with plotly:

In [20]:
znse_ddb = abilab.abiopen("ZnSe_hex_qpt_DDB")

phbst_file, phdos_file = znse_ddb.anaget_phbst_and_phdos_files()
phbands, phdos = phbst_file.phbands, phdos_file.phdos

phbands.plotly_with_phdos(phdos, units="cm-1");

To download a DDB file from the materials project database:

In [21]:
mgo_ddb = abilab.DdbFile.from_mpid("mp-1009129")
print(mgo_ddb)
================================= File Info =================================
Name: mp-1009129chn5l75l_DDB
Directory: /var/folders/nc/k69spyd12qv2tk3stk2xrxg40000gr/T
Size: 218.73 kb
Access Time: Wed Jun  8 20:05:46 2022
Modification Time: Wed Jun  8 20:05:46 2022
Change Time: Wed Jun  8 20:05:46 2022

================================= Structure =================================
Full Formula (Mg1 O1)
Reduced Formula: MgO
abc   :   2.908638   2.908638   2.656848
angles:  90.000000  90.000000 120.000000
Sites (2)
  #  SP           a         b    c
---  ----  --------  --------  ---
  0  Mg    0         0         0
  1  O     0.333333  0.666667  0.5

Abinit Spacegroup: spgid: 0, num_spatial_symmetries: 12, has_timerev: True, symmorphic: False

================================== DDB Info ==================================

Number of q-points in DDB: 72
guessed_ngqpt: [ 9  9 10] (guess for the q-mesh divisions made by AbiPy)
ecut = 44.000000, ecutsm = 0.000000, nkpt = 405, nsym = 12, usepaw = 0
nsppol 1, nspinor 1, nspden 1, ixc = -116133, occopt = 1, tsmear = 0.010000

Has total energy: False
Has forces: False
Has stress tensor: False

Has (at least one) atomic pertubation: True
Has (at least one diagonal) electric-field perturbation: True
Has (at least one) Born effective charge: True
Has (all) strain terms: False
Has (all) internal strain terms: False
Has (all) piezoelectric terms: False
Has (all) dynamical quadrupole terms: False

Let's use the DdbRobot to compare phonons obtained with different ${\bf k}$-meshes and smearing values:

In [22]:
paths = [
    "mgb2_888k_0.01tsmear_DDB",
    "mgb2_888k_0.04tsmear_DDB",
    "mgb2_121212k_0.01tsmear_DDB",
    "mgb2_121212k_0.04tsmear_DDB",
]

paths = [os.path.join(abidata.dirpath, "refs", "mgb2_phonons_nkpt_tsmear", f) 
         for f in paths]

robot = abilab.DdbRobot()
for path in paths:
    robot.add_file(path, path)
In [23]:
# Define function to change labels:
func = lambda ddb: "nkpt: %s, tsmear: %.2f" % (
    ddb.header["nkpt"], ddb.header["tsmear"])

robot.remap_labels(func)
robot
Out[23]:
  1. nkpt: 256, tsmear: 0.01
  2. nkpt: 256, tsmear: 0.04
  3. nkpt: 864, tsmear: 0.01
  4. nkpt: 864, tsmear: 0.04

Now we can build a dataframe with the most important parameters:

In [24]:
robot.get_params_dataframe()
Out[24]:
nkpt nsppol ecut tsmear occopt ixc nband usepaw
nkpt: 256, tsmear: 0.01 256 1 35.0 0.01 4 1 8 0
nkpt: 256, tsmear: 0.04 256 1 35.0 0.04 4 1 8 0
nkpt: 864, tsmear: 0.01 864 1 35.0 0.01 4 1 8 0
nkpt: 864, tsmear: 0.04 864 1 35.0 0.04 4 1 8 0

and check that all DDBs have been computed with the same crystalline structure:

In [25]:
robot.get_lattice_dataframe()
Out[25]:
formula natom alpha beta gamma a b c volume abispg_num spglib_symb spglib_num spglib_lattice_type
nkpt: 256, tsmear: 0.01 Mg1 B2 3 90.0 90.0 120.0 3.086 3.086 3.523 29.055953 0 P6/mmm 191 hexagonal
nkpt: 256, tsmear: 0.04 Mg1 B2 3 90.0 90.0 120.0 3.086 3.086 3.523 29.055953 0 P6/mmm 191 hexagonal
nkpt: 864, tsmear: 0.01 Mg1 B2 3 90.0 90.0 120.0 3.086 3.086 3.523 29.055953 0 P6/mmm 191 hexagonal
nkpt: 864, tsmear: 0.04 Mg1 B2 3 90.0 90.0 120.0 3.086 3.086 3.523 29.055953 0 P6/mmm 191 hexagonal

To analyze the effect of k-sampling/smearing on the vibrational properties:

In [26]:
# Invoke anaddb and store results
r = robot.anaget_phonon_plotters(nqsmall=2)

r.phbands_plotter.gridplot_with_hue("tsmear", with_dos=True);

How to run AbiPy Flows

⚠️ There are two different workflow infrastructures:

Internal AbiPy implementation (abipy.flowtk modules):

  • ✅ Lightweigth, no database required
  • ✅ Designed for rapid prototyping and/or for supporting advanced ABINIT capabilities
  • ❌ No explicit support for high-throughput (HT) applications.

AbiFlows package (requires Fireworks and MongoDB database)

  • HT-oriented: use MongoDB to store workflow status and results for further analysis
  • High-level API designed for HT applications (e.g. phonon calculations for the materials project)
  • ❌ Not all the flowtk workflows are immediately available in AbiFlows.

Here, we mainly discuss the abipy.flowtk API.

In order to run a Flow, we need two configurations files:

  1. scheduler.yml providing:

    • scheduler parameters such as days, hours, minutes, max_njobs_inqueue, max_ncores_used, …
  1. manager.yml providing:

    • list of shell commands to be executed before running ABINIT
    • list of modules to load
    • options for the queue manager (bluegene, moab, pbspro, sge, shell, slurm, torque)

See this page for examples or use the abidoc.py script and the syntax:

  • abidoc.py scheduler
  • abidoc.py manager
  • abidoc.py manager slurm

One usually start by generating an AbinitInput for GS:

In [27]:
def make_scf_input(ecut=2, ngkpt=(4, 4, 4)):
    """
    Generate an `AbinitInput` to perform GS calculation for AlAs.

    Args:
        ecut: Cutoff energy in Ha.
        ngkpt: k-mesh divisions

    Return:
        `AbinitInput` object
    """
    gs_inp = abilab.AbinitInput(structure="AlAs.cif",
                                pseudos=["13al.pspnc", "33as.pspnc"])

    # Set the value of the Abinit variables needed for GS runs.
    gs_inp.set_vars(
        nband=4,
        ecut=ecut,
        ngkpt=ngkpt,
        nshiftk=4,
        shiftk=[0.0, 0.0, 0.5,   # This gives the usual fcc Monkhorst-Pack grid
                0.0, 0.5, 0.0,
                0.5, 0.0, 0.0,
                0.5, 0.5, 0.5],
        tolvrs=1.0e-10,
    )

    return gs_inp
In [28]:
make_scf_input()
Out[28]:
##############################################
#### SECTION: basic
##############################################
nband 4
ecut 2
ngkpt 4 4 4
nshiftk 4
shiftk
0.0 0.0 0.5
0.0 0.5 0.0
0.5 0.0 0.0
0.5 0.5 0.5
tolvrs 1e-10
##############################################
#### SECTION: files
##############################################
indata_prefix indata/in
tmpdata_prefix tmpdata/tmp
outdata_prefix outdata/out
pp_dirpath /Users/gmatteo/git_repos/abipy_imec_2022
pseudos 13al.pspnc 33as.pspnc
##############################################
#### STRUCTURE
##############################################
natom 2
ntypat 2
typat 1 2
znucl 13 33
xred
0.0000000000 0.0000000000 0.0000000000
0.2500000000 0.2500000000 0.2500000000
acell 1.0 1.0 1.0
rprim
6.4972715472 0.0000000000 3.7512014767
2.1657571824 6.1256863603 3.7512014767
0.0000000000 0.0000000000 7.5024029535

From an AbiniInput one can easily build more complicate workflows:

In [29]:
def build_flow_alas_phonons():
    """
    Build and return a Flow to compute the dynamical matrix on a (2, 2, 2) qmesh
    as well as DDK and Born effective charges.
    The final DDB with all perturbations will be merged automatically and placed
    in the Flow `outdir` directory.
    """
    from abipy import flowtk
    scf_input = make_scf_input(ecut=6, ngkpt=(4, 4, 4))
    return flowtk.PhononFlow.from_scf_input("flow_alas_phonons", scf_input,
                                            ph_ngqpt=(2, 2, 2), with_becs=True)
Abipy will call Abinit to get the list of DFPT perturbations and…
In [30]:
flow_phbands = build_flow_alas_phonons()
flow_phbands.get_graphviz()
Out[30]:
flow PhononFlow, node_id=574589, workdir=flow_alas_phonons clusterw0 Work (w0) clusterw1 PhononWork (w1) w0_t0 w0_t0 ScfTask w1_t0 w1_t0 DdkTask w0_t0->w1_t0 WFK w1_t1 w1_t1 DdkTask w0_t0->w1_t1 WFK w1_t2 w1_t2 DdkTask w0_t0->w1_t2 WFK w1_t3 w1_t3 BecTask w0_t0->w1_t3 WFK w1_t4 w1_t4 BecTask w0_t0->w1_t4 WFK w1_t5 w1_t5 PhononTask w0_t0->w1_t5 WFK w1_t6 w1_t6 PhononTask w0_t0->w1_t6 WFK w1_t7 w1_t7 PhononTask w0_t0->w1_t7 WFK w1_t8 w1_t8 PhononTask w0_t0->w1_t8 WFK w1_t9 w1_t9 PhononTask w0_t0->w1_t9 WFK w1_t10 w1_t10 PhononTask w0_t0->w1_t10 WFK w1_t0->w1_t3 DDK w1_t0->w1_t4 DDK w1_t1->w1_t3 DDK w1_t1->w1_t4 DDK w1_t2->w1_t3 DDK w1_t2->w1_t4 DDK

How to run calculations?

The simplest way to start the scheduler from the shell is via the syntax:

run_elastic.py --scheduler # -s for the short option

For non-trivial Flows, we suggest to put the scheduler in background and use nohup so that we can disconnect from the shell session without killing the scheduler.

nohup run_elastic.py --s > log 2> err &

Obviously, it is possible to submit a Slurm script that executes the script on the compute note with 1 core.

To interact with the Flow, one can also use the abirun.py script, e.g:

abirun.py FLOWDIR status

Selected examples of AbiPy Flows

ElasticWork

This flow computes:

  • the rigid-atom elastic tensor
  • the rigid-atom piezoelectric tensor (insulators only)
  • the internal strain tensor
  • the atomic relaxation corrections to the elastic and piezoelectric tensor

Python example

scf_input = make_scf_input() # Build input for GS calculation

elast_work = flowtk.ElasticWork.from_scf_input(scf_input, 
                                               with_relaxed_ion=True, 
                                               with_piezo=True)

Dependency Graph:


  • Indipendent perturbations are computed in parallel with optimized MPI-params.
  • Restart capabilities (e.g. timeout limit) and error handlers
  • Intermediate DDB files are automatically merged.
  • Final DDB file automatically produced in the outdata directory of the Work.

Effective masses with DFPT

This flow performs:

  • GS-SCF run followed by NSCF run with k-path to locate band edges automatically
  • Compute $\epsilon^{\alpha\beta}_{n\bf{k}}$ and the effective mass tensor at the band edges using $|u_{n\mathbf{k}}\rangle$, and the k-derivatives $|u_{n\mathbf{k}}^\alpha\rangle$ $H^\alpha_{\mathbf{k}}$, $H^{\alpha\beta}_{\mathbf{k}}$

  • For the formalism, see J. Laflamme Janssen, et. al. Phys. Rev. B 93, 205147

  • 1260 systems computed as a preliminary step for polaron studies

Python API:

flow = flowtk.Flow("flow_effmass_dfpt")

# Build input for GS SCF calculation.
scf_input = make_scf_input()

# This object implements all the worflow logic
from abipy.flowtk.effmass_works import EffMassAutoDFPTWork
work = EffMassAutoDFPTWork.from_scf_input(scf_input) 

flow.register_work(work)

Dependency Graph


  • 1260 systems computed as a preliminary step for polaron studies

Workflows do not necessarily imply HT applications

  • Sometimes, we need to address rather technical/fundamental questions
  • For instance, one may ask whether the treatment of the dipole interaction is enough to obtain an accurate interpolation of the e-ph scattering potentials
  • Answering this question required hundreds of DFPT + WFQ + EPH calculations along a very dense q-path (300 points):


We used this AbiPy script to automate most of the steps:


NB: This is a simplified version with just 2 q-points in the path. In our work, we used 278 points.